﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.ComponentModel;

namespace BYRForum.Binding.SectionChoose
{
    public class BoardItem
    {
        private String _name;
        public String Name
        {
            get
            {
                return _name;
            }
            set
            {
                if (value != _name)
                {
                    _name = value;
                    NotifyPropertyChanged("Name");
                }
            }
        }

        private String _description;
        public String Description
        {
            get
            {
                return _description;
            }
            set
            {
                if (value != _description)
                {
                    _description = value;
                    NotifyPropertyChanged("Description");
                }
            }
        }

        private String _byrclass;
        public String ByrClass
        {
            get
            {
                return _byrclass;
            }
            set
            {
                if (value != _byrclass)
                {
                    _byrclass = value;
                    NotifyPropertyChanged("ByrClass");
                }
            }
        }

        private String _section;
        public String Section
        {
            get
            {
                return _section;
            }
            set
            {
                if (value != _section)
                {
                    _section = value;
                    NotifyPropertyChanged("Section");
                }
            }
        }

        public event PropertyChangedEventHandler PropertyChanged;
        private void NotifyPropertyChanged(String propertyName)
        {
            PropertyChangedEventHandler handler = PropertyChanged;
            if (null != handler)
            {
                handler(this, new PropertyChangedEventArgs(propertyName));
            }
        }
    }
}
